// 本地缓存
class LocalCache {
    setStorage(key,val){
        localStorage.setItem( key, JSON.stringify( val ) )
    }
    getStorage(key){
        return JSON.parse( localStorage.getItem( key ) )
    }
    removeItem(key){
        localStorage.removeItem(key)
    }
    removeAll(){
        localStorage.clear()
    }
}

export default new LocalCache